package homework0301;

public class ObjecrDemo1 {
    public static void main(String[] args) {
        String s1=new String("abc");
        String s2=new String("abc");
        System.out.println(s1.equals(s2));

        StringBuilder builder1=new StringBuilder("123");
        StringBuilder builder2=new StringBuilder("123");
        System.out.println(builder1.equals(builder2));

        Point1 p1=new Point1(100,200);
        Point1 p2=new Point1(100,200);
        System.out.println(p1==p2);
        System.out.println(p1.equals(p2));//重写point方法后返回值为true


      /*  Point1 p=new Point1(100,200);
        System.out.println(p);
        System.out.println(p.toString());

       */
    }



}
